{extend name='base'/}
{block name='content'}
<ul class="breadcrumb no-border no-radius b-b b-light pull-in">
    <li><a href="index.html"><i class="fa fa-home"></i> Home</a></li>
    <li><a href="#">商品管理</a></li>
    <li class="active">商品列表</li>
</ul>
<div class="col-sm-12">
    <section class="panel panel-default">
        <header class="panel-heading font-bold">商品列表</header>
        <div class="panel-body">
            <div class="panel panel-default">
                <div class="panel-heading">
                    <h3 class="panel-title"><a href="{:url('admin/goods/add')}" class="btn btn-success btn-xs">添加商品</a></h3>
                </div>

            </div>
            <table class="table table-hover">
                <thead>
                <tr>
                    <th>gid</th>
                    <th>品牌名称</th>
                    <th>缩略图</th>
                    <th>价格</th>
                    <th>库存</th>
                    <th>货号</th>
                    <th>上架时间</th>
                    <th>操作</th>
                </tr>
                </thead>
                {volist name="goods" id="data"}
                <tbody>
                    <tr>
                        <td width="5%">{$data['gid']}</td>
                        <td>{$data['gname']}</td>
                        <td><img style="width: 50px;height: 50px;" src="{$data['pic']}" alt=""></td>
                        <td>
                            <p>市场价：<del>{$data['marketprice']}</del></p>
                            <p>商城价：{$data['shopprice']}</p>
                        </td>

                        <td>{$data['total']}</td>
                        <td>{$data['gnumber']}</td>
                        <td>{$data['time']}</td>
                        <td>
                            <!-- Single button -->
                            <div class="btn-group">
                                <button type="button" class="btn btn-success btn-xs dropdown-toggle" data-toggle="dropdown">
                                    操作 <span class="caret"></span>
                                </button>
                                <ul class="dropdown-menu" role="menu">
                                    <li><a href="">货品列表</a></li>
                                    <li><a href="{:url('admin/goods/edit',['gid'=>$data['gid']])}">编辑</a></li>
                                    <li><a href="{:url('admin/goods/del',['gid'=>$data['gid']])}">删除</a></li>
                                </ul>
                            </div>

                        </td>
                    </tr>
                    {/volist}
                </tbody>
            </table>
        </div>
    </section>
</div>
{/block}